﻿using System.Windows;
using GalaSoft.MvvmLight.Messaging;

namespace DaphneControls
{
    /// <summary>
    /// Form for addding a new PDN Tag
    /// </summary>
    public partial class PDNTagAddForm : Window
    {
        public PDNTagAddForm()
        {
            InitializeComponent();

            // Register closing window message
            Messenger.Default.Register<NotificationMessage>(this, (nm) =>
            {
                if (nm.Notification == "CloseWindow")
                {
                    if (nm.Sender == this.DataContext)
                        this.Close();
                }
            });
        }
    }
}